class Todo(object):
    current_id=0
    @classmethod
    def change_id(cls):
        Todo.current_id+=1
        new_id=Todo.current_id
        return new_id

    def __init__(self,title,id=0,completed=False):
        self.title=title
        self.id =id if id>0 else Todo.change_id()
        self.completed=completed